class Student:
    def __init__(self, a, b):
        self.name = a
        self.student_id = b
        self.score = 0

    def set_score(self, new_score):  # 更新学生成绩
        self.score = new_score

    def print_info(self):
        print(f"学生{self.name} 学号{self. student_id} 成绩{self.score}")


student1 = Student("张三", "S001")
student2 = Student("李四", "S002")
student3 = Student("王五", "S003")

student1.set_score(95)
student2.set_score(85)
student3.set_score(92)
student1.set_score(98)

student1.print_info()
student2.print_info()
student3.print_info()
